package com.itheima.spring.bestpractive.vo.req.employee;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Pattern;
import lombok.Data;

import java.util.Date;

/**
 * @version 1.0
 * @author: HZY
 * @date: 2025/6/27 11:23
 * @Content:
 */
@Data
public class EmpReqAdminVo {

    @NotNull(message = "[员工姓名]不能为空")
    @Schema(description = "员工姓名")
    private String name;

    @NotNull(message = "[员工性别]不能为空")
    @Schema(description = "员工性别，取值为男或女")
    private String gender;

    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    @Schema(description = "员工出生日期")
    private Date birthDate;

    @Pattern(regexp = "^\\+?[0-9]{7,15}$", message = "电话号码格式不正确")
    @Schema(description = "联系方式（电话）")
    private String phone;

    @Schema(description = "员工邮箱")
    private String email;

    @NotNull(message = "[所属部门]不能为空")
    @Schema(description = "所属部门")
    private Long departmentId;

    @Schema(description = "岗位名称")
    private String position;

    @NotNull(message = "[员工密码]不能为空")
    @Schema(description = "员工密码")
    private String password;

    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    @Schema(description = "入职时间")
    private Date hireDate;

    @Schema(description = "员工身份证号码")
    private String idCard;

}
